import api from '@/api';

export default {
  namespace: 'resource',
  state: {

  },

  effects: {
    *queryResources({ payload }, { call, put }) {
      return yield call(api.resource.queryResources, payload);
    },
    *queryResource({ payload }, { call, put }) {
      return yield call(api.resource.queryResource, payload);
    },
    *onlineResource({ payload }, { call, put }) {
      return yield call(api.resource.onlineResource, payload);
    },
    *offlineResource({ payload }, { call, put }) {
      return yield call(api.resource.offlineResource, payload);
    },
    *queryResourceRange({ payload }, { call, put }) {
      return yield call(api.resource.queryResourceRange, payload);
    },
  },

  reducers: {

  },
};
